
<%=allt(allt(xcompany.address1)+[ ]+allt(xcompany.address2))%>
<%if not empty(xcompany.ntn)%><%=iif(left(searchresults.depositid,3)=[019],[CASH SALE],[DEBIT SALE])%>
<%=xcompany.ntn%>
<%=iif(left(searchresults.depositid,3)=[019],[CASH SALE],[DEBIT SALE])%>
<%if not empty(xcompany.fbrposid) %>
<%endif%>
<%if not empty(fbrnumberreceived)%>
<%endif%>
<%=[POSID# ]+ALLT(xcompany.fbrposid)%> <%=[FBR# ]+ALLT(fbrinv)%>
<%endif%> <%if not empty(memo)%><%=allt(memo)%>
<%endif%><%=[INV# ]+ALLT(TRANSID)+[ ]+ttoc(dtime)%>
| # | DETAILS | <%if haskglibs%>KGs | LIBs | CTNs | RATE/LIB | RATE/KG | <%else%> <%if haszctn%>UNIT | <%endif%> <%if haszunit%>PCS | <%endif%>QTY | RATE | <%endif haskglibs%> <%if hastax=.t.%>TAX% | VAT | <%endif%>TOTAL | <%if hasdiscount%>DISC | NET AMOUNT | <%endif%>
| <%=RECNO()%> | <%=icase(isurdu=2,allt(DESC)+iif(empty(textra),[],[ ]+allt(textra)),isurdu=1,iif(empty(textra),allt(desc),allt(textra)),allt(desc))%> |
<%if haskglibs%>
<%=iif(empty(KGQTY),' ',KGQTY)%> | <%=iif(empty(libsQTY),' ',libsQTY)%> | <%=iif(empty(thectnqty),' ',thectnqty)%> | <%=iif(empty(rateperlib),' ',rateperlib)%> | <%=iif(empty(rateperkg),' ',rateperkg)%> | <%else%> <%if haszctn%><%=zctn%> | <%endif%> <%if haszunit%><%=iif(empty(thectnqty),' ',thectnqty)%> | <%endif%><%=thectnqty%> | <%=rateperkg%> | <%endif haskglibs%> <%if hastax=.t.%><%=iif(empty(thetaxprate),' ',transform(thetaxprate)+[%])%> | <%=iif(empty(itemtx),' ',transform(itemtx,'999999999.99'))%> | <%endif%><%=ROUND(qty*rate,0)%> | <% roundeddisc=icase(discount=round(discount,0),round(discount,0),round(discount,2)) %> <%if hasdiscount%><%=iif(empty(roundeddisc),' ',transform(roundeddisc))%> | <%=ROUND(qty*rate-roundeddisc,0)%> | <%endif%>
<%='OPERATOR '+ALLT(theuser)+' '+IIF(EMPTY(REPT_SALEMAN),'','SOLD BY: '+REPT_SALEMAN)%>
<%if NOT EMPTY(LASTMESSAGE) %><%=LASTMESSAGE%>
<%endif%>